Skip to content

Fix spinner/progress hanging on error during download#14

Merged
RichardBray merged 3 commits intomainfrom
fix/spinner-hang
Feb 13, 2026
Merged

Fix spinner/progress hanging on error during download#14
RichardBray merged 3 commits intomainfrom
fix/spinner-hang

Conversation

@RichardBray
Copy link
Copy Markdown
Owner

@RichardBray RichardBray commented Feb 13, 2026

Summary

  • Clear the terminal spinner/progress line (\r\x1b[K) before printing error messages on all failure paths in ffmpeg.ts, downloader.ts, and index.ts
  • Release the stream reader in a finally block in downloader.ts to prevent the process from hanging when a mid-download error occurs
  • Add docs/ to .gitignore

Test plan

  • Download a normal mp4 tweet — confirm progress and completion display correctly
  • Download an HLS tweet — confirm spinner clears on success
  • Test with an invalid/broken URL — confirm no hanging spinner, error displays cleanly
  • Kill ffmpeg mid-HLS-download — confirm spinner clears and error message appears

🤖 Generated with Claude Code


Open with Devin

Clear the terminal line before printing error messages so the spinner
or progress indicator doesn't remain visible after failures. Also
release the stream reader in a finally block to prevent the process
from hanging on mid-download errors.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 4 additional findings.

Open in Devin Review

Richard Oliver Bray and others added 2 commits February 13, 2026 18:34
Tests cover HLS download, custom output path, invalid URL handling,
non-video tweets, spinner cleanup, and orphan process detection.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add project guide for Claude Code with build instructions and local
testing workflow. Decouple spinner animation (80ms) from file-size
polling (2s) so the spinner actually visibly spins.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@RichardBray RichardBray merged commit b6c873e into main Feb 13, 2026
1 check passed
@RichardBray RichardBray deleted the fix/spinner-hang branch February 13, 2026 19:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant